<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><link rel="stylesheet" type="text/css" href="style.css" /><script type="text/javascript" src="highlight.js"></script></head><body><pre><span class="hs-comment">{-
(c) The University of Glasgow 2006
(c) The GRASP/AQUA Project, Glasgow University, 1992-1998

\section[NameEnv]{@NameEnv@: name environments}
-}</span><span>
</span><span id="line-7"></span><span>
</span><span id="line-8"></span><span class="hs-pragma">{-# LANGUAGE CPP #-}</span><span>
</span><span id="line-9"></span><span class="hs-pragma">{-# LANGUAGE BangPatterns #-}</span><span>
</span><span id="line-10"></span><span class="hs-pragma">{-# LANGUAGE ScopedTypeVariables #-}</span><span>
</span><span id="line-11"></span><span>
</span><span id="line-12"></span><span class="hs-keyword">module</span><span> </span><span class="hs-identifier">GHC.Types.Name.Env</span><span> </span><span class="hs-special">(</span><span>
</span><span id="line-13"></span><span>        </span><span class="annot"><span class="hs-comment">-- * Var, Id and TyVar environments (maps)</span></span><span>
</span><span id="line-14"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier">NameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-15"></span><span>
</span><span id="line-16"></span><span>        </span><span class="annot"><span class="hs-comment">-- ** Manipulating these environments</span></span><span>
</span><span id="line-17"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#mkNameEnv"><span class="hs-identifier">mkNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#mkNameEnvWith"><span class="hs-identifier">mkNameEnvWith</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-18"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#emptyNameEnv"><span class="hs-identifier">emptyNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#isEmptyNameEnv"><span class="hs-identifier">isEmptyNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-19"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#unitNameEnv"><span class="hs-identifier">unitNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#nameEnvElts"><span class="hs-identifier">nameEnvElts</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-20"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#extendNameEnv_C"><span class="hs-identifier">extendNameEnv_C</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#extendNameEnv_Acc"><span class="hs-identifier">extendNameEnv_Acc</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#extendNameEnv"><span class="hs-identifier">extendNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-21"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#extendNameEnvList"><span class="hs-identifier">extendNameEnvList</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#extendNameEnvList_C"><span class="hs-identifier">extendNameEnvList_C</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-22"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#filterNameEnv"><span class="hs-identifier">filterNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#anyNameEnv"><span class="hs-identifier">anyNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-23"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#plusNameEnv"><span class="hs-identifier">plusNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#plusNameEnv_C"><span class="hs-identifier">plusNameEnv_C</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#plusNameEnv_CD"><span class="hs-identifier">plusNameEnv_CD</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#plusNameEnv_CD2"><span class="hs-identifier">plusNameEnv_CD2</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#alterNameEnv"><span class="hs-identifier">alterNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-24"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#lookupNameEnv"><span class="hs-identifier">lookupNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#lookupNameEnv_NF"><span class="hs-identifier">lookupNameEnv_NF</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#delFromNameEnv"><span class="hs-identifier">delFromNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#delListFromNameEnv"><span class="hs-identifier">delListFromNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-25"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#elemNameEnv"><span class="hs-identifier">elemNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#mapNameEnv"><span class="hs-identifier">mapNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#disjointNameEnv"><span class="hs-identifier">disjointNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-26"></span><span>
</span><span id="line-27"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier">DNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-28"></span><span>
</span><span id="line-29"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#emptyDNameEnv"><span class="hs-identifier">emptyDNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-30"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#lookupDNameEnv"><span class="hs-identifier">lookupDNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-31"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#delFromDNameEnv"><span class="hs-identifier">delFromDNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#filterDNameEnv"><span class="hs-identifier">filterDNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-32"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#mapDNameEnv"><span class="hs-identifier">mapDNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-33"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#adjustDNameEnv"><span class="hs-identifier">adjustDNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#alterDNameEnv"><span class="hs-identifier">alterDNameEnv</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#extendDNameEnv"><span class="hs-identifier">extendDNameEnv</span></a></span><span class="hs-special">,</span><span>
</span><span id="line-34"></span><span>        </span><span class="annot"><span class="hs-comment">-- ** Dependency analysis</span></span><span>
</span><span id="line-35"></span><span>        </span><span class="annot"><a href="GHC.Types.Name.Env.html#depAnal"><span class="hs-identifier">depAnal</span></a></span><span>
</span><span id="line-36"></span><span>    </span><span class="hs-special">)</span><span> </span><span class="hs-keyword">where</span><span class="hs-cpp">

#include &quot;HsVersions.h&quot;
</span><span>
</span><span id="line-40"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Prelude.html"><span class="hs-identifier">GHC.Prelude</span></a></span><span>
</span><span id="line-41"></span><span>
</span><span id="line-42"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Data.Graph.Directed.html"><span class="hs-identifier">GHC.Data.Graph.Directed</span></a></span><span>
</span><span id="line-43"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Types.Name.html"><span class="hs-identifier">GHC.Types.Name</span></a></span><span>
</span><span id="line-44"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Types.Unique.FM.html"><span class="hs-identifier">GHC.Types.Unique.FM</span></a></span><span>
</span><span id="line-45"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Types.Unique.DFM.html"><span class="hs-identifier">GHC.Types.Unique.DFM</span></a></span><span>
</span><span id="line-46"></span><span class="hs-keyword">import</span><span> </span><span class="annot"><a href="GHC.Data.Maybe.html"><span class="hs-identifier">GHC.Data.Maybe</span></a></span><span>
</span><span id="line-47"></span><span>
</span><span id="line-48"></span><span class="hs-comment">{-
************************************************************************
*                                                                      *
\subsection{Name environment}
*                                                                      *
************************************************************************
-}</span><span>
</span><span id="line-55"></span><span>
</span><span id="line-56"></span><span class="hs-comment">{-
Note [depAnal determinism]
~~~~~~~~~~~~~~~~~~~~~~~~~~
depAnal is deterministic provided it gets the nodes in a deterministic order.
The order of lists that get_defs and get_uses return doesn't matter, as these
are only used to construct the edges, and stronglyConnCompFromEdgedVertices is
deterministic even when the edges are not in deterministic order as explained
in Note [Deterministic SCC] in GHC.Data.Graph.Directed.
-}</span><span>
</span><span id="line-65"></span><span>
</span><span id="line-66"></span><span class="annot"><a href="GHC.Types.Name.Env.html#depAnal"><span class="hs-identifier hs-type">depAnal</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-keyword">forall</span><span> </span><span id="local-6989586621680816467"><span class="annot"><a href="#local-6989586621680816467"><span class="hs-identifier hs-type">node</span></a></span></span><span class="hs-operator">.</span><span>
</span><span id="line-67"></span><span>           </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816467"><span class="hs-identifier hs-type">node</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span class="hs-special">]</span><span class="hs-special">)</span><span>      </span><span class="hs-comment">-- Defs</span><span>
</span><span id="line-68"></span><span>        </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816467"><span class="hs-identifier hs-type">node</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span class="hs-special">]</span><span class="hs-special">)</span><span>      </span><span class="hs-comment">-- Uses</span><span>
</span><span id="line-69"></span><span>        </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="#local-6989586621680816467"><span class="hs-identifier hs-type">node</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-70"></span><span>        </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="../../containers/src/Data.Graph.html#SCC"><span class="hs-identifier hs-type">SCC</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816467"><span class="hs-identifier hs-type">node</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-71"></span><span class="hs-comment">-- Perform dependency analysis on a group of definitions,</span><span>
</span><span id="line-72"></span><span class="hs-comment">-- where each definition may define more than one Name</span><span>
</span><span id="line-73"></span><span class="hs-comment">--</span><span>
</span><span id="line-74"></span><span class="hs-comment">-- The get_defs and get_uses functions are called only once per node</span><span>
</span><span id="line-75"></span><span id="depAnal"><span class="annot"><span class="annottext">depAnal :: forall node.
(node -&gt; [Name]) -&gt; (node -&gt; [Name]) -&gt; [node] -&gt; [SCC node]
</span><a href="GHC.Types.Name.Env.html#depAnal"><span class="hs-identifier hs-var hs-var">depAnal</span></a></span></span><span> </span><span id="local-6989586621680816263"><span class="annot"><span class="annottext">node -&gt; [Name]
</span><a href="#local-6989586621680816263"><span class="hs-identifier hs-var">get_defs</span></a></span></span><span> </span><span id="local-6989586621680816262"><span class="annot"><span class="annottext">node -&gt; [Name]
</span><a href="#local-6989586621680816262"><span class="hs-identifier hs-var">get_uses</span></a></span></span><span> </span><span id="local-6989586621680816261"><span class="annot"><span class="annottext">[node]
</span><a href="#local-6989586621680816261"><span class="hs-identifier hs-var">nodes</span></a></span></span><span>
</span><span id="line-76"></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[Node Int node] -&gt; [SCC node]
forall key payload.
Uniquable key =&gt;
[Node key payload] -&gt; [SCC payload]
</span><a href="GHC.Data.Graph.Directed.html#stronglyConnCompFromEdgedVerticesUniq"><span class="hs-identifier hs-var">stronglyConnCompFromEdgedVerticesUniq</span></a></span><span> </span><span class="annot"><span class="annottext">[Node Int node]
</span><a href="#local-6989586621680816259"><span class="hs-identifier hs-var">graph_nodes</span></a></span><span>
</span><span id="line-77"></span><span>  </span><span class="hs-keyword">where</span><span>
</span><span id="line-78"></span><span>    </span><span id="local-6989586621680816259"><span class="annot"><span class="annottext">graph_nodes :: [Node Int node]
</span><a href="#local-6989586621680816259"><span class="hs-identifier hs-var hs-var">graph_nodes</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">((node, Int) -&gt; Node Int node) -&gt; [(node, Int)] -&gt; [Node Int node]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="annot"><span class="annottext">(node, Int) -&gt; Node Int node
</span><a href="#local-6989586621680816258"><span class="hs-identifier hs-var">mk_node</span></a></span><span> </span><span class="annot"><span class="annottext">[(node, Int)]
</span><a href="#local-6989586621680816257"><span class="hs-identifier hs-var">keyed_nodes</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Data.Graph.Directed.html#Node"><span class="hs-identifier hs-type">Node</span></a></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span> </span><span class="annot"><a href="#local-6989586621680816467"><span class="hs-identifier hs-type">node</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-79"></span><span>    </span><span id="local-6989586621680816257"><span class="annot"><span class="annottext">keyed_nodes :: [(node, Int)]
</span><a href="#local-6989586621680816257"><span class="hs-identifier hs-var hs-var">keyed_nodes</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[node]
</span><a href="#local-6989586621680816261"><span class="hs-identifier hs-var">nodes</span></a></span><span> </span><span class="annot"><span class="annottext">[node] -&gt; [Int] -&gt; [(node, Int)]
forall a b. [a] -&gt; [b] -&gt; [(a, b)]
</span><a href="../../base/src/GHC.List.html#zip"><span class="hs-operator hs-var">`zip`</span></a></span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><span class="annottext">Int
</span><span class="hs-number">1</span></span><span class="hs-glyph">::</span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span class="hs-special">)</span><span class="hs-glyph">..</span><span class="hs-special">]</span><span>
</span><span id="line-80"></span><span>    </span><span id="local-6989586621680816258"><span class="annot"><span class="annottext">mk_node :: (node, Int) -&gt; Node Int node
</span><a href="#local-6989586621680816258"><span class="hs-identifier hs-var hs-var">mk_node</span></a></span></span><span> </span><span class="hs-special">(</span><span id="local-6989586621680816254"><span class="annot"><span class="annottext">node
</span><a href="#local-6989586621680816254"><span class="hs-identifier hs-var">node</span></a></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621680816253"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621680816253"><span class="hs-identifier hs-var">key</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">=</span><span>
</span><span id="line-81"></span><span>      </span><span class="hs-keyword">let</span><span> </span><span class="hs-glyph">!</span><span id="local-6989586621680816252"><span class="annot"><span class="annottext">edges :: [Int]
</span><a href="#local-6989586621680816252"><span class="hs-identifier hs-var hs-var">edges</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">(Name -&gt; Maybe Int) -&gt; [Name] -&gt; [Int]
forall a b. (a -&gt; Maybe b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/Data.Maybe.html#mapMaybe"><span class="hs-identifier hs-var">mapMaybe</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">NameEnv Int -&gt; Name -&gt; Maybe Int
forall a. NameEnv a -&gt; Name -&gt; Maybe a
</span><a href="GHC.Types.Name.Env.html#lookupNameEnv"><span class="hs-identifier hs-var">lookupNameEnv</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv Int
</span><a href="#local-6989586621680816250"><span class="hs-identifier hs-var">key_map</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">node -&gt; [Name]
</span><a href="#local-6989586621680816262"><span class="hs-identifier hs-var">get_uses</span></a></span><span> </span><span class="annot"><span class="annottext">node
</span><a href="#local-6989586621680816254"><span class="hs-identifier hs-var">node</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-82"></span><span>      </span><span class="hs-keyword">in</span><span> </span><span class="annot"><span class="annottext">node -&gt; Int -&gt; [Int] -&gt; Node Int node
forall key payload. payload -&gt; key -&gt; [key] -&gt; Node key payload
</span><a href="GHC.Data.Graph.Directed.html#DigraphNode"><span class="hs-identifier hs-var">DigraphNode</span></a></span><span> </span><span class="annot"><span class="annottext">node
</span><a href="#local-6989586621680816254"><span class="hs-identifier hs-var">node</span></a></span><span> </span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621680816253"><span class="hs-identifier hs-var">key</span></a></span><span> </span><span class="annot"><span class="annottext">[Int]
</span><a href="#local-6989586621680816252"><span class="hs-identifier hs-var">edges</span></a></span><span>
</span><span id="line-83"></span><span>
</span><span id="line-84"></span><span>    </span><span class="annot"><a href="#local-6989586621680816250"><span class="hs-identifier hs-type">key_map</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><span class="hs-identifier hs-type">Int</span></span><span>   </span><span class="hs-comment">-- Maps a Name to the key of the decl that defines it</span><span>
</span><span id="line-85"></span><span>    </span><span id="local-6989586621680816250"><span class="annot"><span class="annottext">key_map :: NameEnv Int
</span><a href="#local-6989586621680816250"><span class="hs-identifier hs-var hs-var">key_map</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(Name, Int)] -&gt; NameEnv Int
forall a. [(Name, a)] -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#mkNameEnv"><span class="hs-identifier hs-var">mkNameEnv</span></a></span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816248"><span class="hs-identifier hs-var">name</span></a></span><span class="hs-special">,</span><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621680816247"><span class="hs-identifier hs-var">key</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">|</span><span> </span><span class="hs-special">(</span><span id="local-6989586621680816246"><span class="annot"><span class="annottext">node
</span><a href="#local-6989586621680816246"><span class="hs-identifier hs-var">node</span></a></span></span><span class="hs-special">,</span><span> </span><span id="local-6989586621680816247"><span class="annot"><span class="annottext">Int
</span><a href="#local-6989586621680816247"><span class="hs-identifier hs-var">key</span></a></span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">[(node, Int)]
</span><a href="#local-6989586621680816257"><span class="hs-identifier hs-var">keyed_nodes</span></a></span><span class="hs-special">,</span><span> </span><span id="local-6989586621680816248"><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816248"><span class="hs-identifier hs-var">name</span></a></span></span><span> </span><span class="hs-glyph">&lt;-</span><span> </span><span class="annot"><span class="annottext">node -&gt; [Name]
</span><a href="#local-6989586621680816263"><span class="hs-identifier hs-var">get_defs</span></a></span><span> </span><span class="annot"><span class="annottext">node
</span><a href="#local-6989586621680816246"><span class="hs-identifier hs-var">node</span></a></span><span class="hs-special">]</span><span>
</span><span id="line-86"></span><span>
</span><span id="line-87"></span><span class="hs-comment">{-
************************************************************************
*                                                                      *
\subsection{Name environment}
*                                                                      *
************************************************************************
-}</span><span>
</span><span id="line-94"></span><span>
</span><span id="line-95"></span><span class="hs-comment">-- | Name Environment</span><span>
</span><span id="line-96"></span><span class="hs-keyword">type</span><span> </span><span id="NameEnv"><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-var">NameEnv</span></a></span></span><span> </span><span id="local-6989586621680816245"><span class="annot"><a href="#local-6989586621680816245"><span class="hs-identifier hs-type">a</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><a href="GHC.Types.Unique.FM.html#UniqFM"><span class="hs-identifier hs-type">UniqFM</span></a></span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816245"><span class="hs-identifier hs-type">a</span></a></span><span>       </span><span class="hs-comment">-- Domain is Name</span><span>
</span><span id="line-97"></span><span>
</span><span id="line-98"></span><span id="local-6989586621680816443"><span class="annot"><a href="GHC.Types.Name.Env.html#emptyNameEnv"><span class="hs-identifier hs-type">emptyNameEnv</span></a></span><span>       </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816443"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-99"></span><span id="local-6989586621680816439"><span class="annot"><a href="GHC.Types.Name.Env.html#isEmptyNameEnv"><span class="hs-identifier hs-type">isEmptyNameEnv</span></a></span><span>     </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816439"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span></span><span>
</span><span id="line-100"></span><span id="local-6989586621680816449"><span class="annot"><a href="GHC.Types.Name.Env.html#mkNameEnv"><span class="hs-identifier hs-type">mkNameEnv</span></a></span><span>          </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span class="hs-special">,</span><span class="annot"><a href="#local-6989586621680816449"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816449"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-101"></span><span id="local-6989586621680816413"><span class="annot"><a href="GHC.Types.Name.Env.html#mkNameEnvWith"><span class="hs-identifier hs-type">mkNameEnvWith</span></a></span><span>      </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816413"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="#local-6989586621680816413"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816413"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-102"></span><span id="local-6989586621680816448"><span class="annot"><a href="GHC.Types.Name.Env.html#nameEnvElts"><span class="hs-identifier hs-type">nameEnvElts</span></a></span><span>        </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816448"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="#local-6989586621680816448"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">]</span></span><span>
</span><span id="line-103"></span><span id="local-6989586621680816420"><span class="annot"><a href="GHC.Types.Name.Env.html#alterNameEnv"><span class="hs-identifier hs-type">alterNameEnv</span></a></span><span>       </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816420"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816420"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816420"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816420"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-104"></span><span id="local-6989586621680816384"><span class="annot"><a href="GHC.Types.Name.Env.html#extendNameEnv_C"><span class="hs-identifier hs-type">extendNameEnv_C</span></a></span><span>    </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816384"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816384"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816384"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816384"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816384"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816384"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-105"></span><span id="local-6989586621680816372"><span id="local-6989586621680816373"><span class="annot"><a href="GHC.Types.Name.Env.html#extendNameEnv_Acc"><span class="hs-identifier hs-type">extendNameEnv_Acc</span></a></span><span>  </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816373"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816372"><span class="hs-identifier hs-type">b</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816372"><span class="hs-identifier hs-type">b</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816373"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816372"><span class="hs-identifier hs-type">b</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816372"><span class="hs-identifier hs-type">b</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816373"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816372"><span class="hs-identifier hs-type">b</span></a></span></span></span><span>
</span><span id="line-106"></span><span id="local-6989586621680816431"><span class="annot"><a href="GHC.Types.Name.Env.html#extendNameEnv"><span class="hs-identifier hs-type">extendNameEnv</span></a></span><span>      </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816431"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816431"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816431"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-107"></span><span id="local-6989586621680816404"><span class="annot"><a href="GHC.Types.Name.Env.html#plusNameEnv"><span class="hs-identifier hs-type">plusNameEnv</span></a></span><span>        </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816404"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816404"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816404"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-108"></span><span id="local-6989586621680816400"><span class="annot"><a href="GHC.Types.Name.Env.html#plusNameEnv_C"><span class="hs-identifier hs-type">plusNameEnv_C</span></a></span><span>      </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816400"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816400"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816400"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816400"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816400"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816400"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-109"></span><span id="local-6989586621680816396"><span class="annot"><a href="GHC.Types.Name.Env.html#plusNameEnv_CD"><span class="hs-identifier hs-type">plusNameEnv_CD</span></a></span><span>     </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816396"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816396"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816396"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816396"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816396"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816396"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816396"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816396"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-110"></span><span id="local-6989586621680816390"><span class="annot"><a href="GHC.Types.Name.Env.html#plusNameEnv_CD2"><span class="hs-identifier hs-type">plusNameEnv_CD2</span></a></span><span>    </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816390"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816390"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816390"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816390"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816390"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816390"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-111"></span><span id="local-6989586621680816427"><span class="annot"><a href="GHC.Types.Name.Env.html#extendNameEnvList"><span class="hs-identifier hs-type">extendNameEnvList</span></a></span><span>  </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816427"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span class="hs-special">,</span><span class="annot"><a href="#local-6989586621680816427"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816427"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-112"></span><span id="local-6989586621680816366"><span class="annot"><a href="GHC.Types.Name.Env.html#extendNameEnvList_C"><span class="hs-identifier hs-type">extendNameEnvList_C</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816366"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816366"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-glyph">-&gt;</span><span class="annot"><a href="#local-6989586621680816366"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816366"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="hs-special">(</span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span class="hs-special">,</span><span class="annot"><a href="#local-6989586621680816366"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816366"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-113"></span><span id="local-6989586621680816362"><span class="annot"><a href="GHC.Types.Name.Env.html#delFromNameEnv"><span class="hs-identifier hs-type">delFromNameEnv</span></a></span><span>     </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816362"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816362"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-114"></span><span id="local-6989586621680816358"><span class="annot"><a href="GHC.Types.Name.Env.html#delListFromNameEnv"><span class="hs-identifier hs-type">delListFromNameEnv</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816358"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">[</span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span class="hs-special">]</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816358"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-115"></span><span id="local-6989586621680816408"><span class="annot"><a href="GHC.Types.Name.Env.html#elemNameEnv"><span class="hs-identifier hs-type">elemNameEnv</span></a></span><span>        </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816408"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span></span><span>
</span><span id="line-116"></span><span id="local-6989586621680816435"><span class="annot"><a href="GHC.Types.Name.Env.html#unitNameEnv"><span class="hs-identifier hs-type">unitNameEnv</span></a></span><span>        </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816435"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816435"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-117"></span><span id="local-6989586621680816452"><span class="annot"><a href="GHC.Types.Name.Env.html#lookupNameEnv"><span class="hs-identifier hs-type">lookupNameEnv</span></a></span><span>      </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816452"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816452"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-118"></span><span id="local-6989586621680816340"><span class="annot"><a href="GHC.Types.Name.Env.html#lookupNameEnv_NF"><span class="hs-identifier hs-type">lookupNameEnv_NF</span></a></span><span>   </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816340"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816340"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-119"></span><span id="local-6989586621680816354"><span class="annot"><a href="GHC.Types.Name.Env.html#filterNameEnv"><span class="hs-identifier hs-type">filterNameEnv</span></a></span><span>      </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816354"><span class="hs-identifier hs-type">elt</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816354"><span class="hs-identifier hs-type">elt</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816354"><span class="hs-identifier hs-type">elt</span></a></span></span><span>
</span><span id="line-120"></span><span id="local-6989586621680816350"><span class="annot"><a href="GHC.Types.Name.Env.html#anyNameEnv"><span class="hs-identifier hs-type">anyNameEnv</span></a></span><span>         </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816350"><span class="hs-identifier hs-type">elt</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816350"><span class="hs-identifier hs-type">elt</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span></span><span>
</span><span id="line-121"></span><span id="local-6989586621680816379"><span id="local-6989586621680816380"><span class="annot"><a href="GHC.Types.Name.Env.html#mapNameEnv"><span class="hs-identifier hs-type">mapNameEnv</span></a></span><span>         </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816380"><span class="hs-identifier hs-type">elt1</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816379"><span class="hs-identifier hs-type">elt2</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816380"><span class="hs-identifier hs-type">elt1</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816379"><span class="hs-identifier hs-type">elt2</span></a></span></span></span><span>
</span><span id="line-122"></span><span id="local-6989586621680816345"><span class="annot"><a href="GHC.Types.Name.Env.html#disjointNameEnv"><span class="hs-identifier hs-type">disjointNameEnv</span></a></span><span>    </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816345"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#NameEnv"><span class="hs-identifier hs-type">NameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816345"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span></span><span>
</span><span id="line-123"></span><span>
</span><span id="line-124"></span><span id="nameEnvElts"><span class="annot"><span class="annottext">nameEnvElts :: forall a. NameEnv a -&gt; [a]
</span><a href="GHC.Types.Name.Env.html#nameEnvElts"><span class="hs-identifier hs-var hs-var">nameEnvElts</span></a></span></span><span> </span><span id="local-6989586621680816244"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816244"><span class="hs-identifier hs-var">x</span></a></span></span><span>         </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">NameEnv a -&gt; [a]
forall key elt. UniqFM key elt -&gt; [elt]
</span><a href="GHC.Types.Unique.FM.html#eltsUFM"><span class="hs-identifier hs-var">eltsUFM</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816244"><span class="hs-identifier hs-var">x</span></a></span><span>
</span><span id="line-125"></span><span id="emptyNameEnv"><span class="annot"><span class="annottext">emptyNameEnv :: forall a. NameEnv a
</span><a href="GHC.Types.Name.Env.html#emptyNameEnv"><span class="hs-identifier hs-var hs-var">emptyNameEnv</span></a></span></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">UniqFM Name a
forall key elt. UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#emptyUFM"><span class="hs-identifier hs-var">emptyUFM</span></a></span><span>
</span><span id="line-126"></span><span id="isEmptyNameEnv"><span class="annot"><span class="annottext">isEmptyNameEnv :: forall a. NameEnv a -&gt; Bool
</span><a href="GHC.Types.Name.Env.html#isEmptyNameEnv"><span class="hs-identifier hs-var hs-var">isEmptyNameEnv</span></a></span></span><span>        </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">UniqFM Name a -&gt; Bool
forall key elt. UniqFM key elt -&gt; Bool
</span><a href="GHC.Types.Unique.FM.html#isNullUFM"><span class="hs-identifier hs-var">isNullUFM</span></a></span><span>
</span><span id="line-127"></span><span id="unitNameEnv"><span class="annot"><span class="annottext">unitNameEnv :: forall a. Name -&gt; a -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#unitNameEnv"><span class="hs-identifier hs-var hs-var">unitNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816238"><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816238"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816237"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816237"><span class="hs-identifier hs-var">y</span></a></span></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Name -&gt; a -&gt; UniqFM Name a
forall key elt. Uniquable key =&gt; key -&gt; elt -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#unitUFM"><span class="hs-identifier hs-var">unitUFM</span></a></span><span> </span><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816238"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816237"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-128"></span><span id="extendNameEnv"><span class="annot"><span class="annottext">extendNameEnv :: forall a. NameEnv a -&gt; Name -&gt; a -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#extendNameEnv"><span class="hs-identifier hs-var hs-var">extendNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816234"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816234"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816233"><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816233"><span class="hs-identifier hs-var">y</span></a></span></span><span> </span><span id="local-6989586621680816232"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816232"><span class="hs-identifier hs-var">z</span></a></span></span><span>   </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">NameEnv a -&gt; Name -&gt; a -&gt; NameEnv a
forall key elt.
Uniquable key =&gt;
UniqFM key elt -&gt; key -&gt; elt -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#addToUFM"><span class="hs-identifier hs-var">addToUFM</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816234"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816233"><span class="hs-identifier hs-var">y</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816232"><span class="hs-identifier hs-var">z</span></a></span><span>
</span><span id="line-129"></span><span id="extendNameEnvList"><span class="annot"><span class="annottext">extendNameEnvList :: forall a. NameEnv a -&gt; [(Name, a)] -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#extendNameEnvList"><span class="hs-identifier hs-var hs-var">extendNameEnvList</span></a></span></span><span> </span><span id="local-6989586621680816229"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816229"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816228"><span class="annot"><span class="annottext">[(Name, a)]
</span><a href="#local-6989586621680816228"><span class="hs-identifier hs-var">l</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">NameEnv a -&gt; [(Name, a)] -&gt; NameEnv a
forall key elt.
Uniquable key =&gt;
UniqFM key elt -&gt; [(key, elt)] -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#addListToUFM"><span class="hs-identifier hs-var">addListToUFM</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816229"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">[(Name, a)]
</span><a href="#local-6989586621680816228"><span class="hs-identifier hs-var">l</span></a></span><span>
</span><span id="line-130"></span><span id="lookupNameEnv"><span class="annot"><span class="annottext">lookupNameEnv :: forall a. NameEnv a -&gt; Name -&gt; Maybe a
</span><a href="GHC.Types.Name.Env.html#lookupNameEnv"><span class="hs-identifier hs-var hs-var">lookupNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816225"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816225"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816224"><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816224"><span class="hs-identifier hs-var">y</span></a></span></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">NameEnv a -&gt; Name -&gt; Maybe a
forall key elt. Uniquable key =&gt; UniqFM key elt -&gt; key -&gt; Maybe elt
</span><a href="GHC.Types.Unique.FM.html#lookupUFM"><span class="hs-identifier hs-var">lookupUFM</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816225"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816224"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-131"></span><span id="alterNameEnv"><span class="annot"><span class="annottext">alterNameEnv :: forall a. (Maybe a -&gt; Maybe a) -&gt; NameEnv a -&gt; Name -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#alterNameEnv"><span class="hs-identifier hs-var hs-var">alterNameEnv</span></a></span></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Maybe a -&gt; Maybe a) -&gt; UniqFM Name a -&gt; Name -&gt; UniqFM Name a
forall key elt.
Uniquable key =&gt;
(Maybe elt -&gt; Maybe elt) -&gt; UniqFM key elt -&gt; key -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#alterUFM"><span class="hs-identifier hs-var">alterUFM</span></a></span><span>
</span><span id="line-132"></span><span id="mkNameEnv"><span class="annot"><span class="annottext">mkNameEnv :: forall a. [(Name, a)] -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#mkNameEnv"><span class="hs-identifier hs-var hs-var">mkNameEnv</span></a></span></span><span>     </span><span id="local-6989586621680816219"><span class="annot"><span class="annottext">[(Name, a)]
</span><a href="#local-6989586621680816219"><span class="hs-identifier hs-var">l</span></a></span></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(Name, a)] -&gt; UniqFM Name a
forall key elt. Uniquable key =&gt; [(key, elt)] -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#listToUFM"><span class="hs-identifier hs-var">listToUFM</span></a></span><span> </span><span class="annot"><span class="annottext">[(Name, a)]
</span><a href="#local-6989586621680816219"><span class="hs-identifier hs-var">l</span></a></span><span>
</span><span id="line-133"></span><span id="mkNameEnvWith"><span class="annot"><span class="annottext">mkNameEnvWith :: forall a. (a -&gt; Name) -&gt; [a] -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#mkNameEnvWith"><span class="hs-identifier hs-var hs-var">mkNameEnvWith</span></a></span></span><span> </span><span id="local-6989586621680816217"><span class="annot"><span class="annottext">a -&gt; Name
</span><a href="#local-6989586621680816217"><span class="hs-identifier hs-var">f</span></a></span></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">[(Name, a)] -&gt; NameEnv a
forall a. [(Name, a)] -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#mkNameEnv"><span class="hs-identifier hs-var">mkNameEnv</span></a></span><span> </span><span class="annot"><span class="annottext">([(Name, a)] -&gt; NameEnv a)
-&gt; ([a] -&gt; [(Name, a)]) -&gt; [a] -&gt; NameEnv a
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">(a -&gt; (Name, a)) -&gt; [a] -&gt; [(Name, a)]
forall a b. (a -&gt; b) -&gt; [a] -&gt; [b]
</span><a href="../../base/src/GHC.Base.html#map"><span class="hs-identifier hs-var">map</span></a></span><span> </span><span class="hs-special">(</span><span class="hs-glyph">\</span><span id="local-6989586621680816215"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816215"><span class="hs-identifier hs-var">a</span></a></span></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">a -&gt; Name
</span><a href="#local-6989586621680816217"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816215"><span class="hs-identifier hs-var">a</span></a></span><span class="hs-special">,</span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816215"><span class="hs-identifier hs-var">a</span></a></span><span class="hs-special">)</span><span class="hs-special">)</span><span>
</span><span id="line-134"></span><span id="elemNameEnv"><span class="annot"><span class="annottext">elemNameEnv :: forall a. Name -&gt; NameEnv a -&gt; Bool
</span><a href="GHC.Types.Name.Env.html#elemNameEnv"><span class="hs-identifier hs-var hs-var">elemNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816213"><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816213"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816212"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816212"><span class="hs-identifier hs-var">y</span></a></span></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">Name -&gt; NameEnv a -&gt; Bool
forall key elt. Uniquable key =&gt; key -&gt; UniqFM key elt -&gt; Bool
</span><a href="GHC.Types.Unique.FM.html#elemUFM"><span class="hs-identifier hs-var">elemUFM</span></a></span><span> </span><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816213"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816212"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-135"></span><span id="plusNameEnv"><span class="annot"><span class="annottext">plusNameEnv :: forall a. NameEnv a -&gt; NameEnv a -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#plusNameEnv"><span class="hs-identifier hs-var hs-var">plusNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816210"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816210"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816209"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816209"><span class="hs-identifier hs-var">y</span></a></span></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">NameEnv a -&gt; NameEnv a -&gt; NameEnv a
forall key elt. UniqFM key elt -&gt; UniqFM key elt -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#plusUFM"><span class="hs-identifier hs-var">plusUFM</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816210"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816209"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-136"></span><span id="plusNameEnv_C"><span class="annot"><span class="annottext">plusNameEnv_C :: forall a. (a -&gt; a -&gt; a) -&gt; NameEnv a -&gt; NameEnv a -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#plusNameEnv_C"><span class="hs-identifier hs-var hs-var">plusNameEnv_C</span></a></span></span><span> </span><span id="local-6989586621680816207"><span class="annot"><span class="annottext">a -&gt; a -&gt; a
</span><a href="#local-6989586621680816207"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span id="local-6989586621680816206"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816206"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816205"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816205"><span class="hs-identifier hs-var">y</span></a></span></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(a -&gt; a -&gt; a) -&gt; NameEnv a -&gt; NameEnv a -&gt; NameEnv a
forall elt key.
(elt -&gt; elt -&gt; elt)
-&gt; UniqFM key elt -&gt; UniqFM key elt -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#plusUFM_C"><span class="hs-identifier hs-var">plusUFM_C</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; a -&gt; a
</span><a href="#local-6989586621680816207"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816206"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816205"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-137"></span><span id="plusNameEnv_CD"><span class="annot"><span class="annottext">plusNameEnv_CD :: forall a.
(a -&gt; a -&gt; a) -&gt; NameEnv a -&gt; a -&gt; NameEnv a -&gt; a -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#plusNameEnv_CD"><span class="hs-identifier hs-var hs-var">plusNameEnv_CD</span></a></span></span><span> </span><span id="local-6989586621680816203"><span class="annot"><span class="annottext">a -&gt; a -&gt; a
</span><a href="#local-6989586621680816203"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span id="local-6989586621680816202"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816202"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816201"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816201"><span class="hs-identifier hs-var">d</span></a></span></span><span> </span><span id="local-6989586621680816200"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816200"><span class="hs-identifier hs-var">y</span></a></span></span><span> </span><span id="local-6989586621680816199"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816199"><span class="hs-identifier hs-var">b</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(a -&gt; a -&gt; a) -&gt; NameEnv a -&gt; a -&gt; NameEnv a -&gt; a -&gt; NameEnv a
forall elta eltb eltc key.
(elta -&gt; eltb -&gt; eltc)
-&gt; UniqFM key elta
-&gt; elta
-&gt; UniqFM key eltb
-&gt; eltb
-&gt; UniqFM key eltc
</span><a href="GHC.Types.Unique.FM.html#plusUFM_CD"><span class="hs-identifier hs-var">plusUFM_CD</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; a -&gt; a
</span><a href="#local-6989586621680816203"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816202"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816201"><span class="hs-identifier hs-var">d</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816200"><span class="hs-identifier hs-var">y</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816199"><span class="hs-identifier hs-var">b</span></a></span><span>
</span><span id="line-138"></span><span id="plusNameEnv_CD2"><span class="annot"><span class="annottext">plusNameEnv_CD2 :: forall a.
(Maybe a -&gt; Maybe a -&gt; a) -&gt; NameEnv a -&gt; NameEnv a -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#plusNameEnv_CD2"><span class="hs-identifier hs-var hs-var">plusNameEnv_CD2</span></a></span></span><span> </span><span id="local-6989586621680816197"><span class="annot"><span class="annottext">Maybe a -&gt; Maybe a -&gt; a
</span><a href="#local-6989586621680816197"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span id="local-6989586621680816196"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816196"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816195"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816195"><span class="hs-identifier hs-var">y</span></a></span></span><span>    </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Maybe a -&gt; Maybe a -&gt; a) -&gt; NameEnv a -&gt; NameEnv a -&gt; NameEnv a
forall elta eltb eltc key.
(Maybe elta -&gt; Maybe eltb -&gt; eltc)
-&gt; UniqFM key elta -&gt; UniqFM key eltb -&gt; UniqFM key eltc
</span><a href="GHC.Types.Unique.FM.html#plusUFM_CD2"><span class="hs-identifier hs-var">plusUFM_CD2</span></a></span><span> </span><span class="annot"><span class="annottext">Maybe a -&gt; Maybe a -&gt; a
</span><a href="#local-6989586621680816197"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816196"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816195"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-139"></span><span id="extendNameEnv_C"><span class="annot"><span class="annottext">extendNameEnv_C :: forall a. (a -&gt; a -&gt; a) -&gt; NameEnv a -&gt; Name -&gt; a -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#extendNameEnv_C"><span class="hs-identifier hs-var hs-var">extendNameEnv_C</span></a></span></span><span> </span><span id="local-6989586621680816192"><span class="annot"><span class="annottext">a -&gt; a -&gt; a
</span><a href="#local-6989586621680816192"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span id="local-6989586621680816191"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816191"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816190"><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816190"><span class="hs-identifier hs-var">y</span></a></span></span><span> </span><span id="local-6989586621680816189"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816189"><span class="hs-identifier hs-var">z</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(a -&gt; a -&gt; a) -&gt; NameEnv a -&gt; Name -&gt; a -&gt; NameEnv a
forall key elt.
Uniquable key =&gt;
(elt -&gt; elt -&gt; elt)
-&gt; UniqFM key elt -&gt; key -&gt; elt -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#addToUFM_C"><span class="hs-identifier hs-var">addToUFM_C</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; a -&gt; a
</span><a href="#local-6989586621680816192"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816191"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816190"><span class="hs-identifier hs-var">y</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816189"><span class="hs-identifier hs-var">z</span></a></span><span>
</span><span id="line-140"></span><span id="mapNameEnv"><span class="annot"><span class="annottext">mapNameEnv :: forall elt1 elt2. (elt1 -&gt; elt2) -&gt; NameEnv elt1 -&gt; NameEnv elt2
</span><a href="GHC.Types.Name.Env.html#mapNameEnv"><span class="hs-identifier hs-var hs-var">mapNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816187"><span class="annot"><span class="annottext">elt1 -&gt; elt2
</span><a href="#local-6989586621680816187"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span id="local-6989586621680816186"><span class="annot"><span class="annottext">NameEnv elt1
</span><a href="#local-6989586621680816186"><span class="hs-identifier hs-var">x</span></a></span></span><span>           </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(elt1 -&gt; elt2) -&gt; NameEnv elt1 -&gt; UniqFM Name elt2
forall elt1 elt2 key.
(elt1 -&gt; elt2) -&gt; UniqFM key elt1 -&gt; UniqFM key elt2
</span><a href="GHC.Types.Unique.FM.html#mapUFM"><span class="hs-identifier hs-var">mapUFM</span></a></span><span> </span><span class="annot"><span class="annottext">elt1 -&gt; elt2
</span><a href="#local-6989586621680816187"><span class="hs-identifier hs-var">f</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv elt1
</span><a href="#local-6989586621680816186"><span class="hs-identifier hs-var">x</span></a></span><span>
</span><span id="line-141"></span><span id="extendNameEnv_Acc"><span class="annot"><span class="annottext">extendNameEnv_Acc :: forall a b.
(a -&gt; b -&gt; b) -&gt; (a -&gt; b) -&gt; NameEnv b -&gt; Name -&gt; a -&gt; NameEnv b
</span><a href="GHC.Types.Name.Env.html#extendNameEnv_Acc"><span class="hs-identifier hs-var hs-var">extendNameEnv_Acc</span></a></span></span><span> </span><span id="local-6989586621680816183"><span class="annot"><span class="annottext">a -&gt; b -&gt; b
</span><a href="#local-6989586621680816183"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816182"><span class="annot"><span class="annottext">a -&gt; b
</span><a href="#local-6989586621680816182"><span class="hs-identifier hs-var">y</span></a></span></span><span> </span><span id="local-6989586621680816181"><span class="annot"><span class="annottext">NameEnv b
</span><a href="#local-6989586621680816181"><span class="hs-identifier hs-var">z</span></a></span></span><span> </span><span id="local-6989586621680816180"><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816180"><span class="hs-identifier hs-var">a</span></a></span></span><span> </span><span id="local-6989586621680816179"><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816179"><span class="hs-identifier hs-var">b</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(a -&gt; b -&gt; b) -&gt; (a -&gt; b) -&gt; NameEnv b -&gt; Name -&gt; a -&gt; NameEnv b
forall key elt elts.
Uniquable key =&gt;
(elt -&gt; elts -&gt; elts)
-&gt; (elt -&gt; elts)
-&gt; UniqFM key elts
-&gt; key
-&gt; elt
-&gt; UniqFM key elts
</span><a href="GHC.Types.Unique.FM.html#addToUFM_Acc"><span class="hs-identifier hs-var">addToUFM_Acc</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; b -&gt; b
</span><a href="#local-6989586621680816183"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; b
</span><a href="#local-6989586621680816182"><span class="hs-identifier hs-var">y</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv b
</span><a href="#local-6989586621680816181"><span class="hs-identifier hs-var">z</span></a></span><span> </span><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816180"><span class="hs-identifier hs-var">a</span></a></span><span> </span><span class="annot"><span class="annottext">a
</span><a href="#local-6989586621680816179"><span class="hs-identifier hs-var">b</span></a></span><span>
</span><span id="line-142"></span><span id="extendNameEnvList_C"><span class="annot"><span class="annottext">extendNameEnvList_C :: forall a. (a -&gt; a -&gt; a) -&gt; NameEnv a -&gt; [(Name, a)] -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#extendNameEnvList_C"><span class="hs-identifier hs-var hs-var">extendNameEnvList_C</span></a></span></span><span> </span><span id="local-6989586621680816176"><span class="annot"><span class="annottext">a -&gt; a -&gt; a
</span><a href="#local-6989586621680816176"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816175"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816175"><span class="hs-identifier hs-var">y</span></a></span></span><span> </span><span id="local-6989586621680816174"><span class="annot"><span class="annottext">[(Name, a)]
</span><a href="#local-6989586621680816174"><span class="hs-identifier hs-var">z</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(a -&gt; a -&gt; a) -&gt; NameEnv a -&gt; [(Name, a)] -&gt; NameEnv a
forall key elt.
Uniquable key =&gt;
(elt -&gt; elt -&gt; elt)
-&gt; UniqFM key elt -&gt; [(key, elt)] -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#addListToUFM_C"><span class="hs-identifier hs-var">addListToUFM_C</span></a></span><span> </span><span class="annot"><span class="annottext">a -&gt; a -&gt; a
</span><a href="#local-6989586621680816176"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816175"><span class="hs-identifier hs-var">y</span></a></span><span> </span><span class="annot"><span class="annottext">[(Name, a)]
</span><a href="#local-6989586621680816174"><span class="hs-identifier hs-var">z</span></a></span><span>
</span><span id="line-143"></span><span id="delFromNameEnv"><span class="annot"><span class="annottext">delFromNameEnv :: forall a. NameEnv a -&gt; Name -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#delFromNameEnv"><span class="hs-identifier hs-var hs-var">delFromNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816171"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816171"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816170"><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816170"><span class="hs-identifier hs-var">y</span></a></span></span><span>      </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">NameEnv a -&gt; Name -&gt; NameEnv a
forall key elt.
Uniquable key =&gt;
UniqFM key elt -&gt; key -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#delFromUFM"><span class="hs-identifier hs-var">delFromUFM</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816171"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816170"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-144"></span><span id="delListFromNameEnv"><span class="annot"><span class="annottext">delListFromNameEnv :: forall a. NameEnv a -&gt; [Name] -&gt; NameEnv a
</span><a href="GHC.Types.Name.Env.html#delListFromNameEnv"><span class="hs-identifier hs-var hs-var">delListFromNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816167"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816167"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816166"><span class="annot"><span class="annottext">[Name]
</span><a href="#local-6989586621680816166"><span class="hs-identifier hs-var">y</span></a></span></span><span>  </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">NameEnv a -&gt; [Name] -&gt; NameEnv a
forall key elt.
Uniquable key =&gt;
UniqFM key elt -&gt; [key] -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#delListFromUFM"><span class="hs-identifier hs-var">delListFromUFM</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816167"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">[Name]
</span><a href="#local-6989586621680816166"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-145"></span><span id="filterNameEnv"><span class="annot"><span class="annottext">filterNameEnv :: forall elt. (elt -&gt; Bool) -&gt; NameEnv elt -&gt; NameEnv elt
</span><a href="GHC.Types.Name.Env.html#filterNameEnv"><span class="hs-identifier hs-var hs-var">filterNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816164"><span class="annot"><span class="annottext">elt -&gt; Bool
</span><a href="#local-6989586621680816164"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816163"><span class="annot"><span class="annottext">NameEnv elt
</span><a href="#local-6989586621680816163"><span class="hs-identifier hs-var">y</span></a></span></span><span>       </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(elt -&gt; Bool) -&gt; NameEnv elt -&gt; NameEnv elt
forall elt key. (elt -&gt; Bool) -&gt; UniqFM key elt -&gt; UniqFM key elt
</span><a href="GHC.Types.Unique.FM.html#filterUFM"><span class="hs-identifier hs-var">filterUFM</span></a></span><span> </span><span class="annot"><span class="annottext">elt -&gt; Bool
</span><a href="#local-6989586621680816164"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv elt
</span><a href="#local-6989586621680816163"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-146"></span><span id="anyNameEnv"><span class="annot"><span class="annottext">anyNameEnv :: forall elt. (elt -&gt; Bool) -&gt; NameEnv elt -&gt; Bool
</span><a href="GHC.Types.Name.Env.html#anyNameEnv"><span class="hs-identifier hs-var hs-var">anyNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816161"><span class="annot"><span class="annottext">elt -&gt; Bool
</span><a href="#local-6989586621680816161"><span class="hs-identifier hs-var">f</span></a></span></span><span> </span><span id="local-6989586621680816160"><span class="annot"><span class="annottext">NameEnv elt
</span><a href="#local-6989586621680816160"><span class="hs-identifier hs-var">x</span></a></span></span><span>          </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(elt -&gt; Bool -&gt; Bool) -&gt; Bool -&gt; NameEnv elt -&gt; Bool
forall elt a key. (elt -&gt; a -&gt; a) -&gt; a -&gt; UniqFM key elt -&gt; a
</span><a href="GHC.Types.Unique.FM.html#foldUFM"><span class="hs-identifier hs-var">foldUFM</span></a></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">Bool -&gt; Bool -&gt; Bool
</span><span class="hs-operator hs-var">(||)</span></span><span> </span><span class="annot"><span class="annottext">(Bool -&gt; Bool -&gt; Bool) -&gt; (elt -&gt; Bool) -&gt; elt -&gt; Bool -&gt; Bool
forall b c a. (b -&gt; c) -&gt; (a -&gt; b) -&gt; a -&gt; c
</span><a href="../../base/src/GHC.Base.html#."><span class="hs-operator hs-var">.</span></a></span><span> </span><span class="annot"><span class="annottext">elt -&gt; Bool
</span><a href="#local-6989586621680816161"><span class="hs-identifier hs-var">f</span></a></span><span class="hs-special">)</span><span> </span><span class="annot"><span class="annottext">Bool
</span><span class="hs-identifier hs-var">False</span></span><span> </span><span class="annot"><span class="annottext">NameEnv elt
</span><a href="#local-6989586621680816160"><span class="hs-identifier hs-var">x</span></a></span><span>
</span><span id="line-147"></span><span id="disjointNameEnv"><span class="annot"><span class="annottext">disjointNameEnv :: forall a. NameEnv a -&gt; NameEnv a -&gt; Bool
</span><a href="GHC.Types.Name.Env.html#disjointNameEnv"><span class="hs-identifier hs-var hs-var">disjointNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816157"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816157"><span class="hs-identifier hs-var">x</span></a></span></span><span> </span><span id="local-6989586621680816156"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816156"><span class="hs-identifier hs-var">y</span></a></span></span><span>     </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">NameEnv a -&gt; NameEnv a -&gt; Bool
forall key elt1 elt2. UniqFM key elt1 -&gt; UniqFM key elt2 -&gt; Bool
</span><a href="GHC.Types.Unique.FM.html#disjointUFM"><span class="hs-identifier hs-var">disjointUFM</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816157"><span class="hs-identifier hs-var">x</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816156"><span class="hs-identifier hs-var">y</span></a></span><span>
</span><span id="line-148"></span><span>
</span><span id="line-149"></span><span id="lookupNameEnv_NF"><span class="annot"><span class="annottext">lookupNameEnv_NF :: forall a. NameEnv a -&gt; Name -&gt; a
</span><a href="GHC.Types.Name.Env.html#lookupNameEnv_NF"><span class="hs-identifier hs-var hs-var">lookupNameEnv_NF</span></a></span></span><span> </span><span id="local-6989586621680816152"><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816152"><span class="hs-identifier hs-var">env</span></a></span></span><span> </span><span id="local-6989586621680816151"><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816151"><span class="hs-identifier hs-var">n</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">String -&gt; Maybe a -&gt; a
forall a. HasCallStack =&gt; String -&gt; Maybe a -&gt; a
</span><a href="GHC.Data.Maybe.html#expectJust"><span class="hs-identifier hs-var">expectJust</span></a></span><span> </span><span class="annot"><span class="annottext">String
</span><span class="hs-string">&quot;lookupNameEnv_NF&quot;</span></span><span> </span><span class="hs-special">(</span><span class="annot"><span class="annottext">NameEnv a -&gt; Name -&gt; Maybe a
forall a. NameEnv a -&gt; Name -&gt; Maybe a
</span><a href="GHC.Types.Name.Env.html#lookupNameEnv"><span class="hs-identifier hs-var">lookupNameEnv</span></a></span><span> </span><span class="annot"><span class="annottext">NameEnv a
</span><a href="#local-6989586621680816152"><span class="hs-identifier hs-var">env</span></a></span><span> </span><span class="annot"><span class="annottext">Name
</span><a href="#local-6989586621680816151"><span class="hs-identifier hs-var">n</span></a></span><span class="hs-special">)</span><span>
</span><span id="line-150"></span><span>
</span><span id="line-151"></span><span class="hs-comment">-- | Deterministic Name Environment</span><span>
</span><span id="line-152"></span><span class="hs-comment">--</span><span>
</span><span id="line-153"></span><span class="hs-comment">-- See Note [Deterministic UniqFM] in &quot;GHC.Types.Unique.DFM&quot; for explanation why</span><span>
</span><span id="line-154"></span><span class="hs-comment">-- we need DNameEnv.</span><span>
</span><span id="line-155"></span><span class="hs-keyword">type</span><span> </span><span id="DNameEnv"><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-var">DNameEnv</span></a></span></span><span> </span><span id="local-6989586621680816149"><span class="annot"><a href="#local-6989586621680816149"><span class="hs-identifier hs-type">a</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><a href="GHC.Types.Unique.DFM.html#UniqDFM"><span class="hs-identifier hs-type">UniqDFM</span></a></span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816149"><span class="hs-identifier hs-type">a</span></a></span><span>
</span><span id="line-156"></span><span>
</span><span id="line-157"></span><span id="local-6989586621680816336"><span class="annot"><a href="GHC.Types.Name.Env.html#emptyDNameEnv"><span class="hs-identifier hs-type">emptyDNameEnv</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816336"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-158"></span><span id="emptyDNameEnv"><span class="annot"><span class="annottext">emptyDNameEnv :: forall a. DNameEnv a
</span><a href="GHC.Types.Name.Env.html#emptyDNameEnv"><span class="hs-identifier hs-var hs-var">emptyDNameEnv</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">UniqDFM Name a
forall key elt. UniqDFM key elt
</span><a href="GHC.Types.Unique.DFM.html#emptyUDFM"><span class="hs-identifier hs-var">emptyUDFM</span></a></span><span>
</span><span id="line-159"></span><span>
</span><span id="line-160"></span><span id="local-6989586621680816330"><span class="annot"><a href="GHC.Types.Name.Env.html#lookupDNameEnv"><span class="hs-identifier hs-type">lookupDNameEnv</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816330"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816330"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-161"></span><span id="lookupDNameEnv"><span class="annot"><span class="annottext">lookupDNameEnv :: forall a. DNameEnv a -&gt; Name -&gt; Maybe a
</span><a href="GHC.Types.Name.Env.html#lookupDNameEnv"><span class="hs-identifier hs-var hs-var">lookupDNameEnv</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">UniqDFM Name a -&gt; Name -&gt; Maybe a
forall key elt.
Uniquable key =&gt;
UniqDFM key elt -&gt; key -&gt; Maybe elt
</span><a href="GHC.Types.Unique.DFM.html#lookupUDFM"><span class="hs-identifier hs-var">lookupUDFM</span></a></span><span>
</span><span id="line-162"></span><span>
</span><span id="line-163"></span><span id="local-6989586621680816326"><span class="annot"><a href="GHC.Types.Name.Env.html#delFromDNameEnv"><span class="hs-identifier hs-type">delFromDNameEnv</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816326"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816326"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-164"></span><span id="delFromDNameEnv"><span class="annot"><span class="annottext">delFromDNameEnv :: forall a. DNameEnv a -&gt; Name -&gt; DNameEnv a
</span><a href="GHC.Types.Name.Env.html#delFromDNameEnv"><span class="hs-identifier hs-var hs-var">delFromDNameEnv</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">UniqDFM Name a -&gt; Name -&gt; UniqDFM Name a
forall key elt.
Uniquable key =&gt;
UniqDFM key elt -&gt; key -&gt; UniqDFM key elt
</span><a href="GHC.Types.Unique.DFM.html#delFromUDFM"><span class="hs-identifier hs-var">delFromUDFM</span></a></span><span>
</span><span id="line-165"></span><span>
</span><span id="line-166"></span><span id="local-6989586621680816322"><span class="annot"><a href="GHC.Types.Name.Env.html#filterDNameEnv"><span class="hs-identifier hs-type">filterDNameEnv</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816322"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><span class="hs-identifier hs-type">Bool</span></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816322"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816322"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-167"></span><span id="filterDNameEnv"><span class="annot"><span class="annottext">filterDNameEnv :: forall a. (a -&gt; Bool) -&gt; DNameEnv a -&gt; DNameEnv a
</span><a href="GHC.Types.Name.Env.html#filterDNameEnv"><span class="hs-identifier hs-var hs-var">filterDNameEnv</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(a -&gt; Bool) -&gt; UniqDFM Name a -&gt; UniqDFM Name a
forall elt key. (elt -&gt; Bool) -&gt; UniqDFM key elt -&gt; UniqDFM key elt
</span><a href="GHC.Types.Unique.DFM.html#filterUDFM"><span class="hs-identifier hs-var">filterUDFM</span></a></span><span>
</span><span id="line-168"></span><span>
</span><span id="line-169"></span><span id="local-6989586621680816317"><span id="local-6989586621680816318"><span class="annot"><a href="GHC.Types.Name.Env.html#mapDNameEnv"><span class="hs-identifier hs-type">mapDNameEnv</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816318"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816317"><span class="hs-identifier hs-type">b</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816318"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816317"><span class="hs-identifier hs-type">b</span></a></span></span></span><span>
</span><span id="line-170"></span><span id="mapDNameEnv"><span class="annot"><span class="annottext">mapDNameEnv :: forall a b. (a -&gt; b) -&gt; DNameEnv a -&gt; DNameEnv b
</span><a href="GHC.Types.Name.Env.html#mapDNameEnv"><span class="hs-identifier hs-var hs-var">mapDNameEnv</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(a -&gt; b) -&gt; UniqDFM Name a -&gt; UniqDFM Name b
forall elt1 elt2 key.
(elt1 -&gt; elt2) -&gt; UniqDFM key elt1 -&gt; UniqDFM key elt2
</span><a href="GHC.Types.Unique.DFM.html#mapUDFM"><span class="hs-identifier hs-var">mapUDFM</span></a></span><span>
</span><span id="line-171"></span><span>
</span><span id="line-172"></span><span id="local-6989586621680816311"><span class="annot"><a href="GHC.Types.Name.Env.html#adjustDNameEnv"><span class="hs-identifier hs-type">adjustDNameEnv</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="#local-6989586621680816311"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816311"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816311"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816311"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-173"></span><span id="adjustDNameEnv"><span class="annot"><span class="annottext">adjustDNameEnv :: forall a. (a -&gt; a) -&gt; DNameEnv a -&gt; Name -&gt; DNameEnv a
</span><a href="GHC.Types.Name.Env.html#adjustDNameEnv"><span class="hs-identifier hs-var hs-var">adjustDNameEnv</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(a -&gt; a) -&gt; UniqDFM Name a -&gt; Name -&gt; UniqDFM Name a
forall key elt.
Uniquable key =&gt;
(elt -&gt; elt) -&gt; UniqDFM key elt -&gt; key -&gt; UniqDFM key elt
</span><a href="GHC.Types.Unique.DFM.html#adjustUDFM"><span class="hs-identifier hs-var">adjustUDFM</span></a></span><span>
</span><span id="line-174"></span><span>
</span><span id="line-175"></span><span id="local-6989586621680816307"><span class="annot"><a href="GHC.Types.Name.Env.html#alterDNameEnv"><span class="hs-identifier hs-type">alterDNameEnv</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="hs-special">(</span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816307"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="../../base/src/GHC.Maybe.html#Maybe"><span class="hs-identifier hs-type">Maybe</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816307"><span class="hs-identifier hs-type">a</span></a></span><span class="hs-special">)</span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816307"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816307"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-176"></span><span id="alterDNameEnv"><span class="annot"><span class="annottext">alterDNameEnv :: forall a. (Maybe a -&gt; Maybe a) -&gt; DNameEnv a -&gt; Name -&gt; DNameEnv a
</span><a href="GHC.Types.Name.Env.html#alterDNameEnv"><span class="hs-identifier hs-var hs-var">alterDNameEnv</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">(Maybe a -&gt; Maybe a) -&gt; UniqDFM Name a -&gt; Name -&gt; UniqDFM Name a
forall key elt.
Uniquable key =&gt;
(Maybe elt -&gt; Maybe elt)
-&gt; UniqDFM key elt -&gt; key -&gt; UniqDFM key elt
</span><a href="GHC.Types.Unique.DFM.html#alterUDFM"><span class="hs-identifier hs-var">alterUDFM</span></a></span><span>
</span><span id="line-177"></span><span>
</span><span id="line-178"></span><span id="local-6989586621680816303"><span class="annot"><a href="GHC.Types.Name.Env.html#extendDNameEnv"><span class="hs-identifier hs-type">extendDNameEnv</span></a></span><span> </span><span class="hs-glyph">::</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816303"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.html#Name"><span class="hs-identifier hs-type">Name</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="#local-6989586621680816303"><span class="hs-identifier hs-type">a</span></a></span><span> </span><span class="hs-glyph">-&gt;</span><span> </span><span class="annot"><a href="GHC.Types.Name.Env.html#DNameEnv"><span class="hs-identifier hs-type">DNameEnv</span></a></span><span> </span><span class="annot"><a href="#local-6989586621680816303"><span class="hs-identifier hs-type">a</span></a></span></span><span>
</span><span id="line-179"></span><span id="extendDNameEnv"><span class="annot"><span class="annottext">extendDNameEnv :: forall a. DNameEnv a -&gt; Name -&gt; a -&gt; DNameEnv a
</span><a href="GHC.Types.Name.Env.html#extendDNameEnv"><span class="hs-identifier hs-var hs-var">extendDNameEnv</span></a></span></span><span> </span><span class="hs-glyph">=</span><span> </span><span class="annot"><span class="annottext">UniqDFM Name a -&gt; Name -&gt; a -&gt; UniqDFM Name a
forall key elt.
Uniquable key =&gt;
UniqDFM key elt -&gt; key -&gt; elt -&gt; UniqDFM key elt
</span><a href="GHC.Types.Unique.DFM.html#addToUDFM"><span class="hs-identifier hs-var">addToUDFM</span></a></span><span>
</span><span id="line-180"></span></pre></body></html>